package bpm.domain.document;

import java.io.Serializable;

/**
 * 
 * @author <a mailto="hwangsyin@gmail.com">King</a>
 *
 */
public class LabelView implements Serializable {
	private static final long serialVersionUID = 1L;
	
	public Integer doucmentDefinitionId;
	public Integer id;
	public String key;
	public String name;
	public String description;
	public String value;
	public String dataType;
	public Integer length;
	public Integer editStyle;
	public String editArgument;
	public String displayArgument;
	public boolean loggable;
	public boolean enable;
	
	public String defaultValue;
	
	public LabelView() {}
	public LabelView(Field field) {
		if(field != null) {
			this.id = field.getId();
			this.key = field.getKey();
			this.name = field.getName();
			this.description = field.getDescription();
			this.value = field.getValue();
			this.dataType = field.getDataType();
			this.length = field.getLength();
			this.editStyle = field.getEditStyle();
			this.editArgument = field.getEditArgument();
			this.displayArgument = field.getDisplayArgument();
			this.loggable = field.isLoggable();
			this.enable = field.isEnable();
			this.defaultValue = field.getDefaultValue();
		}
	}
}
